/* 基本样式 */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f7f7f7;
}

/* 容器 */
.container {
    display: flex;
    flex-direction: column;
    max-width: 600px; /* 最大宽度为600px，适应电脑端 */
    margin: 0 auto;
}

/* 游戏分类标题 */
.category-title {
    background-color: #fff;
    padding: 15px;
    border-bottom: 1px solid #ddd;
    text-align: center;
    width: 100%;
    margin: 0 auto;
}

.category-title h2 {
    margin: 0;
    font-size: 24px;
    color: #333;
}

/* 页面主体内容 */
.main-content {
    display: flex;
    margin: 0 auto;
    width: 100%;
    padding: 10px;
}

/* 左侧分类栏 */
.category-list {
    width: 16.66%;
    background-color: #fff;
    border-right: 1px solid #ddd;
    padding: 15px;
    box-sizing: border-box;
    height: 100vh;
    overflow-y: auto;
}

.category-list ul {
    padding: 0;
    list-style-type: none;
}

.category-item {
    font-size: 18px;
    margin: 10px 0;
    padding: 10px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.category-item:hover {
    background-color: #f1f1f1;
}

.category-item.selected {
    background-color: #007bff;
    color: white;
}

/* 右侧游戏展示区域 */
.game-list {
    width: 84.33%;
    padding: 10px;
    box-sizing: border-box;
    height: 100vh;
    overflow-y: auto;
}

.game-screenshots {
    display: flex;
    justify-content: space-between; /* 确保图片之间有间隔 */
    flex-wrap: wrap; /* 允许换行 */
}

.game-screenshots img {
    width: calc(33.33% - 2px); /* 默认每张图片占宽度的1/3，减去间距 */
    height: auto;
    border-radius: 8px; /* 可选：增加圆角 */
    max-width: 100%; /* 防止图片超出父容器 */
}

/* 只有一张图片时，它会占满整行 */
.game-screenshots img:nth-child(1):only-child {
    width: 100%; /* 单张图片占据整行 */
}





